package adfc2.render3d.tex;

import com.sun.opengl.util.texture.Texture;

public class TiledTexture {
    public final Texture texture;
    public final int width;
    public final int height;
    public final TexRefSimple full;
    public final TexRefTile[] tiles;

    public TiledTexture(Texture texture, int width, int height) {
        this.texture = texture;
        this.width = width;
        this.height = height;
        this.full = new TexRefSimple(texture);
        this.tiles = new TexRefTile[width * height];
        for (int i = 0; i < width * height; i++) {
            this.tiles[i] = new TexRefTile(texture, i, width, height);
        }
    }
}
